package map;

public final class KeyClass {

    private int a;
    private String s;
    public KeyClass(){}
    public KeyClass(int a, String s){
        this.a = a;
        this.s = s;
    }
    @Override
    public String toString() {
        StringBuilder builder = new StringBuilder();
        builder.append("KeyClass [a=");
        builder.append(a);
        builder.append(", s=");
        builder.append(s);
        builder.append("]");
        return builder.toString();
    }
    public String toString(KeyClass c) {
        return c.getClass().getName();
    }
    @Override
    public int hashCode() {
        return a+s.hashCode();
    }
    @Override
    public boolean equals(Object obj) {
        return obj.hashCode() == this.hashCode();
    }
    public int getA() {
        return a;
    }
    public String getS() {
        return s;
    }
}
